using System;
using System.Collections.Generic;
using System.Text;

/**
*@file       LoginServerTab.cs
*@brief      process message
*
*@author     graywind
*@version    1.0.0.1
*@data       2012/4/23
*/

//process message
public class LoginServerProcessor
{
    public delegate void LoginServerTabFunc(IMessageOperator op, Int32 session_id, byte[] msg_buffer, UInt32 msg_bytes);

    /// <summary>
/// process message
    /// </summary>
    /// <param name="op">message operator</param>
    /// <param name="session_id">session identifier</param>
    /// <param name="msg_id">message identifier</param>
    /// <param name="msg_buffer">message buffer</param>
    /// <param name="msg_bytes">buffer length</param>
    public static void ProcessMessage(IMessageOperator op, Int32 session_id, UInt32 msg_id, byte[] msg_buffer, UInt32 msg_bytes)
    {
        gwMessageTab<LoginServerTypes, LoginServerTabFunc>.FuncPtrArray[msg_id](op, session_id, msg_buffer, msg_bytes);
    }
}
